package com.system.api.rbac.entity.vo;

import com.fasterxml.jackson.annotation.JsonInclude;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 *  角色树
 * @author: lslands
 * @description:   
 * @version：v1.0
 * @date:    2024/6/12 20:05
 */

@Data
@Builder
@NoArgsConstructor
public class RoleListVo {

    /**
     * 角色Id
     */
    private Long id;
    /**
     * 角色名称
     */
    private String name;
    /**
     * 子集
     */
    @JsonInclude(value = JsonInclude.Include.NON_EMPTY)
    private List<RoleListVo> children;


    public RoleListVo(Long id, String name, List<RoleListVo> children) {
        this.id = id;
        this.name = name;
        this.children = children;
    }
}
